8029cfb0: 27 bd ff d8  ADDIU sp, sp, 0xffffffd8 (-40)
8029cfb4: af bf 00 14  SW ra, sp, 0x14 (20)
8029cfb8: af a4 00 28  SW a0, sp, 0x28 (40)
8029cfbc: af a5 00 2c  SW a1, sp, 0x2c (44)

8029cfc0: 3c 0e 80 34  LUI t6, 0x8034 (32820)
8029cfc4: 25 ce cb e0  ADDIU t6, t6, 0xffffcbe0 (-13344)
8029cfc8: 3c 01 80 36  LUI at, 0x8036 (32822)
8029cfcc: ac 2e 10 e8  SW t6, at, 0x10e8 (4328)            *(0x803610e8) = 0x8033cbe0;

8029cfd0: 3c 01 80 34  LUI at, 0x8034 (32820)
8029cfd4: ac 20 d4 80  SW r0, at, 0xffffd480 (-11136)      *(0x8033d480) = 0;

8029cfd8: 3c 01 80 36  LUI at, 0x8036 (32822)
8029cfdc: a4 20 12 62  SH r0, at, 0x1262 (4706)            *(0x80361262) = 0;

8029cfe0: 3c 01 80 36  LUI at, 0x8036 (32822)
8029cfe4: a4 20 12 64  SH r0, at, 0x1264 (4708)            *(0x80361264) = 0;

8029cfe8: 0c 0b 23 ca  JAL 0x802c8f28 (-2144563416)        0x802c8f28();
8029cfec: 00 00 00 00  NOP

8029cff0: 3c 0f 80 34  LUI t7, 0x8034 (32820)
8029cff4: 85 ef ba ca  LH t7, t7, 0xffffbaca (-17718)
8029cff8: 24 01 00 02  ADDIU at, r0, 0x2 (2)
8029cffc: 15 e1 00 06  BNE t7, at, 0x8029d018 (pc + 0x18)  if (*(0x8033baca) != 2) goto 0x8029d018;
8029d000: 00 00 00 00  NOP

8029d004: 3c 18 80 36  LUI t8, 0x8036 (32822)
8029d008: 87 18 12 5c  LH t8, t8, 0x125c (4700)
8029d00c: 3c 01 80 36  LUI at, 0x8036 (32822)
8029d010: 37 19 00 01  ORI t9, t8, 0x1 (1)
8029d014: a4 39 12 5c  SH t9, at, 0x125c (4700)            *(0x8036125c) |= 1;

*
8029d018: 8f a8 00 2c  LW t0, sp, 0x2c (44)
8029d01c: 11 00 00 68  BEQ r0, t0, 0x8029d1c0 (pc + 0x1a0) if ([sp + 0x2c] == 0) goto 0x8029d1c0;
8029d020: 00 00 00 00  NOP

*
8029d024: 8f a9 00 2c  LW t1, sp, 0x2c (44)
8029d028: 8d 2a 00 10  LW t2, t1, 0x10 (16)
8029d02c: 31 4b ff ff  ANDI t3, t2, 0xffff (65535)
8029d030: a7 ab 00 1a  SH t3, sp, 0x1a (26)                [sp + 0x1a] = ([sp + 0x2c]->off0x10) & 0xffff;

8029d034: 8f ac 00 2c  LW t4, sp, 0x2c (44)
8029d038: 0c 09 df d4  JAL 0x80277f50 (-2144895152)        [sp + 0x1c] = 0x80277f50([sp + 0x2c]->off0x14);
8029d03c: 8d 84 00 14  LW a0, t4, 0x14 (20)
8029d040: af a2 00 1c  SW v0, sp, 0x1c (28)

8029d044: 8f ad 00 2c  LW t5, sp, 0x2c (44)
8029d048: 34 01 ff 00  ORI at, r0, 0xff00 (65280)
8029d04c: 8d ae 00 10  LW t6, t5, 0x10 (16)
8029d050: 31 cf ff 00  ANDI t7, t6, 0xff00 (65280)
8029d054: 11 e1 00 54  BEQ at, t7, 0x8029d1a8 (pc + 0x150) if (0xff00 == ([sp + 0x2c]->off0x10 & 0xff00)) goto 0x8029d1a8;
8029d058: 00 00 00 00  NOP

8029d05c: 0c 0b 27 c1  JAL 0x802c9f04 (-2144559356)        [sp + 0x24] = 0x802c9f04([sp + 0x1c]);
8029d060: 8f a4 00 1c  LW a0, sp, 0x1c (28)
8029d064: af a2 00 24  SW v0, sp, 0x24 (36)

8029d068: 8f b8 00 2c  LW t8, sp, 0x2c (44)
8029d06c: 8f a8 00 24  LW t0, sp, 0x24 (36)
8029d070: 8f 19 00 10  LW t9, t8, 0x10 (16)
8029d074: ad 19 01 88  SW t9, t0, 0x188 (392)             [sp + 0x24]->off0x188 = [sp + 0x2c]->off0x10;

8029d078: 8f a9 00 2c  LW t1, sp, 0x2c (44)
8029d07c: 8f ad 00 24  LW t5, sp, 0x24 (36)
8029d080: 8d 2a 00 10  LW t2, t1, 0x10 (16)
8029d084: 00 0a 5c 02  SRL t3, t2, 0x10 (16)
8029d088: 31 6c 00 ff  ANDI t4, t3, 0xff (255)
8029d08c: ad ac 01 44  SW t4, t5, 0x144 (324)             [sp + 0x24]->off0x144 = ([sp + 0x2c]->off0x10 >> 16) & 0xff;

8029d090: 8f ae 00 1c  LW t6, sp, 0x1c (28)
8029d094: 8f af 00 24  LW t7, sp, 0x24 (36)
8029d098: ad ee 02 0c  SW t6, t7, 0x20c (524)             [sp + 0x24]->off0x20c = [sp + 0x1c];

8029d09c: 8f b8 00 24  LW t8, sp, 0x24 (36)
8029d0a0: af 00 01 c8  SW r0, t8, 0x1c8 (456)             [sp + 0x24]->off0x1c8 = 0;

8029d0a4: 8f a8 00 24  LW t0, sp, 0x24 (36)
8029d0a8: 24 19 00 01  ADDIU t9, r0, 0x1 (1)
8029d0ac: a5 19 01 f6  SH t9, t0, 0x1f6 (502)             [sp + 0x24]->off0x1f6 = 1;

8029d0b0: 8f a9 00 2c  LW t1, sp, 0x2c (44)
8029d0b4: 8f ab 00 24  LW t3, sp, 0x24 (36)
8029d0b8: 25 2a 00 10  ADDIU t2, t1, 0x10 (16)
8029d0bc: ad 6a 02 5c  SW t2, t3, 0x25c (604)             [sp + 0x24]->off0x25c = [sp + 0x2c]+16;

8029d0c0: 8f ac 00 2c  LW t4, sp, 0x2c (44)
8029d0c4: 8d 8d 00 10  LW t5, t4, 0x10 (16)
8029d0c8: 31 ae 00 01  ANDI t6, t5, 0x1 (1)
8029d0cc: 11 c0 00 06  BEQ r0, t6, 0x8029d0e8 (pc + 0x18) if (0 == ([sp + 0x2c]->off0x10 & 1)) goto 0x8029d0e8;
8029d0d0: 00 00 00 00  NOP

8029d0d4: 8f af 00 24  LW t7, sp, 0x24 (36)
8029d0d8: 3c 01 80 36  LUI at, 0x8036 (32822)
8029d0dc: ac 2f 11 58  SW t7, at, 0x1158 (4440)            *(0x80361158) = [sp + 0x24];

8029d0e0: 0c 0d f0 4e  JAL 0x8037c138 (-2143829704)        0x8037c138([sp + 0x24]);
8029d0e4: 8f a4 00 24  LW a0, sp, 0x24 (36)

*
8029d0e8: 8f a4 00 24  LW a0, sp, 0x24 (36)
8029d0ec: 0c 0d f1 47  JAL 0x8037c51c (-2143828708)        [sp + 0x24] = 0x8037c51c([sp + 0x24]);
8029d0f0: 8f a5 00 2c  LW a1, sp, 0x2c (44)

8029d0f4: 8f b8 00 2c  LW t8, sp, 0x2c (44)
8029d0f8: 8f a8 00 24  LW t0, sp, 0x24 (36)
8029d0fc: 87 19 00 00  LH t9, t8, 0x0 (0)
8029d100: 44 99 20 00  MTC1 t9, f4
8029d104: 00 00 00 00  NOP
8029d108: 46 80 21 a0  CVT.S.W f6, f4
8029d10c: e5 06 00 a0  SWC1 f6, t0, 0xa0 (160)             [sp + 0x24]->0xa0 = (float)([sp + 0x2c]->off0x00);

8029d110: 8f a9 00 2c  LW t1, sp, 0x2c (44)
8029d114: 8f ab 00 24  LW t3, sp, 0x24 (36)
8029d118: 85 2a 00 02  LH t2, t1, 0x2 (2)
8029d11c: 44 8a 40 00  MTC1 t2, f8
8029d120: 00 00 00 00  NOP
8029d124: 46 80 42 a0  CVT.S.W f10, f8
8029d128: e5 6a 00 a4  SWC1 f10, t3, 0xa4 (164)            [sp + 0x24]->0xa4 = (float)([sp + 0x2c]->off0x02);

8029d12c: 8f ac 00 2c  LW t4, sp, 0x2c (44)
8029d130: 8f ae 00 24  LW t6, sp, 0x24 (36)
8029d134: 85 8d 00 04  LH t5, t4, 0x4 (4)
8029d138: 44 8d 80 00  MTC1 t5, f16
8029d13c: 00 00 00 00  NOP
8029d140: 46 80 84 a0  CVT.S.W f18, f16
8029d144: e5 d2 00 a8  SWC1 f18, t6, 0xa8 (168)            [sp + 0x24]->0xa8 = (float)([sp + 0x2c]->off0x04);

8029d148: 8f af 00 2c  LW t7, sp, 0x2c (44)
8029d14c: 8f b9 00 24  LW t9, sp, 0x24 (36)
8029d150: 85 f8 00 06  LH t8, t7, 0x6 (6)
8029d154: af 38 00 d0  SW t8, t9, 0xd0 (208)               [sp + 0x24]->0xd0 = [sp + 0x2c]->off0x06;

8029d158: 8f a8 00 2c  LW t0, sp, 0x2c (44)
8029d15c: 8f aa 00 24  LW t2, sp, 0x24 (36)
8029d160: 85 09 00 08  LH t1, t0, 0x8 (8)
8029d164: ad 49 00 d4  SW t1, t2, 0xd4 (212)               [sp + 0x24]->0xd4 = [sp + 0x2c]->off0x08;

8029d168: 8f ab 00 2c  LW t3, sp, 0x2c (44)
8029d16c: 8f ad 00 24  LW t5, sp, 0x24 (36)
8029d170: 85 6c 00 0a  LH t4, t3, 0xa (10)
8029d174: ad ac 00 d8  SW t4, t5, 0xd8 (216)               [sp + 0x24]->0xd8 = [sp + 0x2c]->off0x0a;

8029d178: 8f ae 00 2c  LW t6, sp, 0x2c (44)
8029d17c: 8f b8 00 24  LW t8, sp, 0x24 (36)
8029d180: 85 cf 00 06  LH t7, t6, 0x6 (6)
8029d184: af 0f 00 c4  SW t7, t8, 0xc4 (196)               [sp + 0x24]->0xc4 = [sp + 0x2c]->off0x06;

8029d188: 8f b9 00 2c  LW t9, sp, 0x2c (44)
8029d18c: 8f a9 00 24  LW t1, sp, 0x24 (36)
8029d190: 87 28 00 08  LH t0, t9, 0x8 (8)
8029d194: ad 28 00 c8  SW t0, t1, 0xc8 (200)               [sp + 0x24]->0xc8 = [sp + 0x2c]->off0x08;

8029d198: 8f aa 00 2c  LW t2, sp, 0x2c (44)
8029d19c: 8f ac 00 24  LW t4, sp, 0x24 (36)
8029d1a0: 85 4b 00 0a  LH t3, t2, 0xa (10)
8029d1a4: ad 8b 00 cc  SW t3, t4, 0xcc (204)               [sp + 0x24]->0xcc = [sp + 0x2c]->off0x0a;

*
8029d1a8: 8f ad 00 2c  LW t5, sp, 0x2c (44)
8029d1ac: 8d ae 00 1c  LW t6, t5, 0x1c (28)
8029d1b0: af ae 00 2c  SW t6, sp, 0x2c (44)                [sp + 0x2c] = [sp + 0x2c]->off0x1c;

8029d1b4: 8f af 00 2c  LW t7, sp, 0x2c (44)
8029d1b8: 15 e0 ff 9a  BNE t7, r0, 0x8029d024 (pc - 0x198) if ([sp + 0x2c] != 0) goto 0x8029d024;
8029d1bc: 00 00 00 00  NOP

*
8029d1c0: 10 00 00 01  BEQ r0, r0, 0x8029d1c8 (pc + 0x4)
8029d1c4: 00 00 00 00  NOP
8029d1c8: 8f bf 00 14  LW ra, sp, 0x14 (20)
8029d1cc: 27 bd 00 28  ADDIU sp, sp, 0x28 (40)
8029d1d0: 03 e0 00 08  JR ra
8029d1d4: 00 00 00 00  NOP


*(0x803610e8) = 0x8033cbe0;
*(0x8033d480) = 0;
*(0x80361262) = 0;
*(0x80361264) = 0;
0x802c8f28();
if (*(0x8033baca) != 2) goto 0x8029d018;
*(0x8036125c) |= 1;
8029d018:
if ([sp + 0x2c] == 0) goto 0x8029d1c0;
8029d024:
[sp + 0x1a] = ([sp + 0x2c]->off0x10) & 0xffff;
[sp + 0x1c] = 0x80277f50([sp + 0x2c]->off0x14);
if (0xff00 == ([sp + 0x2c]->off0x10 & 0xff00)) goto 0x8029d1a8;
[sp + 0x24] = 0x802c9f04([sp + 0x1c]);
[sp + 0x24]->off0x188 = [sp + 0x2c]->off0x10;
[sp + 0x24]->off0x144 = ([sp + 0x2c]->off0x10 >> 16) & 0xff;
[sp + 0x24]->off0x20c = [sp + 0x1c];
[sp + 0x24]->off0x1c8 = 0;
[sp + 0x24]->off0x1f6 = 1;
[sp + 0x24]->off0x25c = [sp + 0x2c]+16;
if (0 == ([sp + 0x2c]->off0x10 & 1)) goto 0x8029d0e8;
*(0x80361158) = [sp + 0x24];
0x8037c138([sp + 0x24]);
8029d0e8:
[sp + 0x24] = 0x8037c51c([sp + 0x24]);
[sp + 0x24]->off0xa0 = (float)([sp + 0x2c]->off0x00);
[sp + 0x24]->off0xa4 = (float)([sp + 0x2c]->off0x02);
[sp + 0x24]->off0xa8 = (float)([sp + 0x2c]->off0x04);
[sp + 0x24]->off0xd0 = [sp + 0x2c]->off0x06;
[sp + 0x24]->off0xd4 = [sp + 0x2c]->off0x08;
[sp + 0x24]->off0xd8 = [sp + 0x2c]->off0x0a;
[sp + 0x24]->off0xc4 = [sp + 0x2c]->off0x06;
[sp + 0x24]->off0xc8 = [sp + 0x2c]->off0x08;
[sp + 0x24]->off0xcc = [sp + 0x2c]->off0x0a;
8029d1a8:
[sp + 0x2c] = [sp + 0x2c]->off0x1c;
if ([sp + 0x2c] != 0) goto 0x8029d024;
8029d1c0:


void proc0x8029cfb0(u32 arg1 /* sp + 0x28 */, LIVEOBJECT *p_lo /* sp + 0x2c */)
{

    uint32_t *behav_entry; /* sp + 0x1c */

    *(0x803610e8) = 0x8033cbe0;
    *(0x8033d480) = 0;
    *(0x80361262) = 0;
    *(0x80361264) = 0;
    0x802c8f28();
    if (*(0x8033baca) == 2) {
        *(0x8036125c) |= 1;
    }
    while (p_lo) {
        8029d024:
        [sp + 0x1a] = (p_lo->misc) & 0xffff;
        behav_entry =  0x80277f50(p_lo->type);
        if (0xff00 == (p_lo->misc & 0xff00)) goto 0x8029d1a8;
            [sp + 0x24] = 0x802c9f04([sp + 0x1c]);
            [sp + 0x24]->off0x188 = p_lo->misc;
            [sp + 0x24]->off0x144 = (p_lo->misc >> 16) & 0xff;
            [sp + 0x24]->off0x20c = behav_entry;
            [sp + 0x24]->off0x1c8 = 0;
            [sp + 0x24]->off0x1f6 = 1;
            [sp + 0x24]->off0x25c = &(p_lo->misc);
            if (p_lo->misc & 1) {
                *(0x80361158) = [sp + 0x24];
                0x8037c138([sp + 0x24]);
            }
            [sp + 0x24] = 0x8037c51c([sp + 0x24]);
            [sp + 0x24]->off0xa0 = (float)(p_lo->x);
            [sp + 0x24]->off0xa4 = (float)(p_lo->y);
            [sp + 0x24]->off0xa8 = (float)(p_lo->z);
            [sp + 0x24]->off0xd0 = p_lo->theta;
            [sp + 0x24]->off0xd4 = p_lo->phi;
            [sp + 0x24]->off0xd8 = p_lo->alpha;
            [sp + 0x24]->off0xc4 = p_lo->theta;
            [sp + 0x24]->off0xc8 = p_lo->phi;
            [sp + 0x24]->off0xcc = p_lo->alpha;
        8029d1a8:
        p_lo = p_lo->next;
    }
}
